The invention concerns a process for compressing a succession of binary digital data, especially representative of the pixels or pels (picture elements) of a digitized image; the invention also concerns a device for carrying out such process.
In a digital image acquisition system, the values of the different elementary zones of the image or pixels are transcribed into words. The value of each word represents the "brightness" of the pixel involved. For example, in the field of digital radiology, the radiological image is displayed by a brightness amplifier, intercepted by a camera and the signal of this camera is sampled. The sample sequence thus elaborated represents, for example, a line by line reading by "scanning" of the different pixels of these lines. The sample sequence is digitized, i.e. transformed into a sequence of words. If, for example, each word is coded on 8 bits, which represents a graduation from 0 to 255 from black to white and if an image is defined of 512.times.512 pixels, the memory capacity is great, i.e. 2,097,152 bits to be memorized. When numerous images have to be memorized, a mass storage is indispensable. Storing or memorizing on a magnetic disk is a method that is often used. Generally, a buffer storage of limited capacity is linked up to the mass memory, for the transfer of data. The mass storage is thus "fed" with successive readings of data contained in the buffer memory. However, due to current technological limitations the transfer of the contents of the buffer memory towards the mass storage is an operation which requires time and which restricts the performances of the system to a rhythm of images which is insufficient in certain cases, for example, if it is desired to observe rapid phenomena such as the evolution of a contrast product in the blood system or the heart. It is therefore of interest to compress the representative data of an image by exploiting the spacial and/or temporal redundancies inherent therein. The compression rate defines the gain realized after processing. Therefore, a compression rate of 2 means that the buffer memory having the capacity necessary to memorize a normal complete memory, can also recover representative data of two images, after compression. Since the transfer time between the buffer memory and the mass storage is invariable, this means that the acquisition rhythm of the images can be doubled.
A known manner of compressing a succession of digital data results from the observation that two adjacent pixels are seldom very different. Consequently, it is advantageous to memorize not the pixels X.sub.i, but the differences X.sub.i -X.sub.i-1. In fact, if the pixels X.sub.i are coded on 8 bits, i.e. 256 possible values, the difference of the two adjacent pixels can in most cases be coded on a number of bits lower than 5.
However, if a coding is specified, without loss of data, it is necessary to be able to memorize the important differences between adjacent pixels, the appearance probability of which is low but which nevertheless occur, for the details with very contrasted transitions. In order to overcome this problem, codes of variable length have already been proposed, for example, Huffman codes. Such a code results in a conversion table in which each possible difference value (between -225 and +225 for the example as mentioned herein-above) receives a binary code whose length is inversely proportional to its appearance probability Thus, the difference values that appear the most often upon coding during exploration of the image, pixel by pixel, receive the shortest codes.
The invention concerns several improvements to this type of coding.
In the first instance, the invention thus concerns a process of compressing a succession of binary digital data present in the form of fixed format words representing positive integers of an interval [O,N], comprising subtracting each word from the preceding one in such a way as to obtain each time a difference of variable format comprising a sign bit, wherein the said sign bit is suppressed from the said difference for at least certain absolute values of difference,
if the absolute value of said difference is higher than the value of the preceding word when it is comprised in the first half of the said interval or unit, or
if the absolute value of the said difference is higher than the value of the difference between the number N and the value of the preceding word when it is comprised in the second half of the said interval, and wherein
the thus compressed data is transferred, for example, towards a memory.
Another important object of this invention consists in coding directly the value of the pixel once the difference exceeds, in absolute value, a predetermined number. In fact, if pixels coded on 8 bits are considered, for example, a great difference value requires 9 bits in order to be coded, due to the sign of this difference. It thus becomes advantageous to code directly the pixel on 8 bits, since it is necessarily a positive number. In the example that will be described herein-below, the pixel (of 8 bits) is coded directly once the difference exceeds 31 in absolute value.
Furthermore, another particular object of the present invention consists in defining the given intervals of difference possible and in identifying each interval by a given tag. A suffix comprising a number of bits sufficient to represents all the absolute difference values possible in the interval involved, follows directly the tag and a supplementary bit indicates the sign. This manner of identification of the difference values has the advantage of reducing the "tree structure" of the electronic decoding circuits, i.e. the number of logic tests to be carried out prior to fully recognize a word. Thus, for example, the recognition of the tag could be exploited in order to address a table (read-only memory) directly containing all the possible difference values in the interval corresponding to the tag.
The invention also concerns a device for a compression of a succession of binary digital data present in the form of fixed format words representing positive integers of the interval (O,N) comprising a word input to which are applied the said words, a register forming the memory connected to the said input in order to memorize at each instant the value of the preceding word which is applied to the said input, and a memory to receive a succession of digital data of variable length representative of the succession of the said fixed format words, wherein: means are provided for transferring to the said buffer memory
either the absolute value of difference between the word applied to the said input and the said preceding word if the absolute value of the said difference is higher than the value of the preceding word when it is comprised in the first half of the said interval or if the absolute value of the said difference is higher than the value of the difference between the number N and the value of the preceding word when it is comprised in the second half of the said interval,
or the value of this difference and of its sign in the contrary case.